In the specification of WO01/21602, it is described that oxa and thiazole derivatives of formula (A)
(wherein XA is 1, 2, 3 or 4, mA is 1 or 2, n is 1 or 2, QA is C or N, AA is O or S, ZA is O or a bond, R1A is hydrogen atom or alkyl, XA is CH or N, R2A is H, alkyl etc., R2aA, R2bA and R2cA are hydrogen atom, alkyl, alkoxy, halogen atom, amino or substituted amino (substituted amino is amino substituted with one or two substituents, which may be the same or different, such as alkyl, aryl, arylalkyl, heteroaryl, heteroarylalkyl, cycloheteroalkyl, cycloheteroalkylalkyl, cycloalkyl, cycloalkylalkyl, haloalkyl, hydroxyalkyl, alkoxyalkyl, thioalkyl. In addition, the amino substituednts may be taken together with the nitrogen atom to which they are attached to form 1-pyrrolidinyl, 1-piperidinyl, 1-azepinyl, 4-morpholinyl, 4-thiamorpholinyl, 1-piperazinyl, 4-alkyl-1-piperazinyl, 4-arylalkyl-1-piperazinyl, 4-diarylalkyl-1-piperazinyl, 1-pyrrolidinyl, 1-piperidinyl, or 1-azepinyl (optionally substituted with alkyl, alkoxy, alkylthio, halo, trifluoromethyl, hydroxyl.), R3A is H, alkyl, arylalkyl etc., Y is CO2R4A (R4A is hydrogen atom, alkyl etc.) etc.) and pharmaceutically acceptable salts thereof are useful as antidiabetic and antiobesity agents.